package com.timesheet.gui.efforttracker.composite;

import org.eclipse.swt.SWT;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.DateTime;
import org.eclipse.swt.widgets.Label;

import com.timesheet.gui.efforttracker.controllers.LeaveSearchCompositeController;
import com.timesheet.gui.efforttracker.controllers.WSRDateChooseController;


public class LeaveSearchComposite extends Composite {
	private DateTime dtFrom;
	private DateTime dateTo;
	private Button btnSubmit;

	/**
	 * Create the composite.
	 * 
	 * @param parent
	 * @param style
	 */
	public LeaveSearchComposite(Composite parent, int style) {
		super(parent, style);
		setLayout(new GridLayout(5, false));

		Label lblChooseDate = new Label(this, SWT.NONE);
		lblChooseDate.setText("From");

		dtFrom = new DateTime(this, SWT.BORDER | SWT.DROP_DOWN);
		
		
		Label lblTo = new Label(this, SWT.NONE);
		lblTo.setText("To");
		
		dateTo = new DateTime(this, SWT.BORDER | SWT.DROP_DOWN);

		btnSubmit = new Button(this, SWT.NONE);
		btnSubmit.setText("Submit");
		

		
		
		new LeaveSearchCompositeController(this);
		
		
		

	}

	@Override
	protected void checkSubclass() {
		// Disable the check that prevents subclassing of SWT components
	}

	public DateTime getDtFrom() {
		return dtFrom;
	}
	public DateTime getDateTo() {
		return dateTo;
	}
	public Button getBtnSubmit() {
		return btnSubmit;
	}
}
